package com.wondream.myframework.app.vo.base;

import lombok.Data;

import java.util.List;

@Data
public class PageVO<T> {
    private int pageNo;

    private int pageSize;

    private int total;

    private int pages;

    private List<?> records;

    public void setTotal(int total) {
        this.total = total;
        this.pages = total / this.pageSize + ((total % this.pageSize > 0) ? 1 : 0);
    }
}
